package com.aliwo.design.patterns.strategy.context;

import com.aliwo.design.patterns.strategy.Sort;

/**
 * @author xuyayuan
 * @description 排序策略上下文
 * @date 2021/9/13 13:58
 */
public class SortContext {

    private Sort sort;

    public SortContext (Sort sort) {
        this.sort = sort;
    }

    public int[] sort(int[] arr) {
        sort.sort(arr);
        return arr;
    }

}
